package com.bdqn.zhang.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.ArrayList;
import java.util.List;

/**
 * <Description> <br>
 *
 * @author tao<br>
 * @version 1.0<br>
 * @taskId: <br>
 * @createDate 2019/09/26 15:05 <br>
 * @see com.bdqn.zhang.controller <br>
 */
@Controller
public class UserController {
    @RequestMapping("/list")
    public String getUserList(Model model){
        System.out.println("成功访问了 jstljsp");
        List<String> list= new ArrayList<String>();
        list.add("张三");
        list.add("李四");
        model.addAttribute("users",list);
        return "demo";
    }

    @RequestMapping("/demoLayui")
    public String toDemoLayui(Model model){
        return "demoLayui";
    }

    @RequestMapping("/demoLayui2")
    public String toDemoLayui2(Model model){
        return "demoLayui2";
    }

    @RequestMapping("/demoLayui3")
    public String toDemoLayui3(Model model){
        return "demoLayui3";
    }
}
